package com.fms.gui.templateCreator.components.button;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;
import javax.swing.JFrame;

public class CloseFrameButton extends JButton implements ActionListener
{
	/**
	 * 
	 */
	private static final long serialVersionUID = -6964841940002475855L;
	private JFrame owner;
	public CloseFrameButton()
	{
		this.addActionListener(this);
	}
	
	public void setOwnerFrame(JFrame _owner)
	{
		this.owner = _owner;
	}

	public void actionPerformed(ActionEvent arg0)
	{
		this.owner.setVisible(false);
		
	}
}
